Nevron Open Vision Documentation
Nevron.Nov.DataStructures Namespace / NStringMap<T> Class / GetSimilarItems Method
The string to search similar strings for.
The string similarity context that provides information for the edit distance budget and the cost of the various edit operations.


In This Topic
    GetSimilarItems Method
    In This Topic
    Gets the subset of all key-value pairs in this map whose key is found to be similar to the given string using the specified string similarity context.
    Syntax
    'Declaration
     
    
    Public Function GetSimilarItems( _
       ByVal str As System.String, _
       ByVal context As NStringSimilarityContext _
    ) As INSet(Of NKeyValuePair(Of String,T))
    'Usage
     
    
    Dim instance As NStringMap(Of T)
    Dim str As System.String
    Dim context As NStringSimilarityContext
    Dim value As INSet(Of NKeyValuePair(Of String,T))
     
    value = instance.GetSimilarItems(str, context)
    public INSet<NKeyValuePair<string,T>> GetSimilarItems( 
       System.string str,
       NStringSimilarityContext context
    )

    Parameters

    str
    The string to search similar strings for.
    context
    The string similarity context that provides information for the edit distance budget and the cost of the various edit operations.
    Remarks
    The similarity is determined by the edit distance (a.k.a. Damerau–Levenshtein distance) of the strings, i.e. the number of insertions, removals, substitutions and transpositions of adjacent characters needed to transform one of the strings to the other.
    Requirements

    Target Platforms: Windows 11, Windows 10, Windows 7, Windows Server 2019, Windows Server 2016, Windows Server 2012 R2, Windows Server 2012, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later)

    See Also